package com.learn.ert.controller;

import com.baomidou.mybatisplus.extension.api.R;
import com.learn.ert.mapper.ErLeaveMapper;
import com.learn.ert.base.BaseApiService;
import com.learn.ert.base.BaseResponse;
import com.learn.ert.service.ErLeaveService;
import com.learn.ert.utils.HttpUtils;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.Map;


/**
 * 
 *
 * @author sjf
 * @email 2334593702@qq.com
 * @date 2020-08-14 17:47:02
 */
@RestController
@RequestMapping("api/erleave")
@Api(tags = "留言管理接口")
public class ErLeaveController {
    @Autowired
    private ErLeaveService erLeaveService;
/*

    */
/**
     * 列表
     *//*

    @RequestMapping("/list")
  //  @RequiresPermissions("api:erleave:list")
    public R list(@RequestParam Map<String, Object> params){
        PageUtils page = erLeaveMapper.queryPage(params);

        return R.ok().put("page", page);
    }


    */
/**
     * 信息
     *//*

    @RequestMapping("/info/{leId}")
   // @RequiresPermissions("api:erleave:info")
    public R info(@PathVariable("leId") Integer leId){
		ErLeaveEntity erLeave = erLeaveMapper.selectById(leId);

        return R.ok().put("erLeave", erLeave);
    }

    */
/**
     * 保存
     *//*

    @RequestMapping("/save")
   // @RequiresPermissions("api:erleave:save")
    public R save(@RequestBody ErLeaveEntity erLeave){
		erLeaveMapper.insert(erLeave);

        return R.ok();
    }

    */
/**
     * 修改
     *//*

    @RequestMapping("/update")
    //@RequiresPermissions("api:erleave:update")
    public R update(@RequestBody ErLeaveEntity erLeave){
		erLeaveMapper.updateById(erLeave);

        return R.ok();
    }

    */
/**
     * 删除
     *//*

//    @RequestMapping("/delete")
//    //@RequiresPermissions("api:erleave:delete")
//    public R delete(@RequestBody Integer[] leIds){
//		erLeaveMapper.removeByIds(Arrays.asList(leIds));
//
//        return R.ok();
//    }
*/

}
